package cn.vcjf.weapp.api.active.service.impl;

import cn.vcjf.weapp.api.active.entity.GoodsActive;
import cn.vcjf.weapp.api.active.mapper.GoodsActiveMapper;
import cn.vcjf.weapp.api.active.service.GoodsActiveService;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author zhengzihang
 * @since 2018-09-26
 */
@Service("goodsActiveService")
public class GoodsActiveServiceImpl extends ServiceImpl<GoodsActiveMapper, GoodsActive> implements GoodsActiveService {


	@Override
	public GoodsActive findActiveInfo(GoodsActive goodsActive) {
		return baseMapper.findActiveInfo(goodsActive);
	}

	@Override
	public int updateExpireActive() {
		return baseMapper.updateExpireActive();
	}

	@Override
	public Page<GoodsActive> selectHotActive(Page<GoodsActive> page, EntityWrapper<GoodsActive> wrapper) {
		return page.setRecords(baseMapper.selectHotActive(page,wrapper));
	}

}
